package android.slc.base.config;

import android.slc.base.utils.AppPathUtils;
import android.slc.box.commonlibrary.compat.SlcResourceUtils;

public class ConstantsBase {

    public static class Key {
        public static final String KEY_TITLE_LABEL = "titleLabel";
        public static final String KEY_IS_REFRESH = "isRefresh";
        public static final String KEY_REFRESH = "refresh";
        public static final String KEY_YEAR = "year";
        public static final String KEY_MONTH = "month";
        public final static String KEY_SCAN_CODE_TYPE = "type";
        public final static String KEY_SCAN_CODE_VALUE = "value";
    }

    public static class Value {
        public static final String VALUE_TIME_PATTERN_BY_Y_MC_COMMON = "yyyy-MM";
        public static final String VALUE_TIME_PATTERN_BY_D_COMMON = "dd";
        public static final String VALUE_TIME_PATTERN_BY_Y_D_COMMON = "yyyy-MM-dd";
        public static final String VALUE_TIME_PATTERN_BY_Y_S_COMMON = "yyyy-MM-dd HH:mm:ss";
        public static final String VALUE_TIME_PATTERN_BY_H_M_COMMON = "HH:mm";
        public static final String VALUE_TIME_PATTERN_BY_M_S_COMMON = "mm:ss";
        public static final String VALUE_TIME_PATTERN_BY_Y_D_CH = "yyyy年MM月dd日";
        public static final String VALUE_TIME_PATTERN_BY_Y_MC_CH = "yyyy年MM月";
        public static final String VALUE_TIME_PATTERN_BY_Y_M_CH = "yyyy年MM月dd日 HH:mm";

        public final static String VALUE_STATUS_NORMAL = "0";
        public final static String VALUE_STATUS_DEACTIVATE = "1";

        public final static int VALUE_STATE_UNREAD = 0;
        public final static int VALUE_STATE_HAVE_READ = 1;

        public final static int VALUE_AM = 0;
        public final static int VALUE_PM = 1;

        public static int VALUE_SERVICE_NOTIFY_ID_START = 2000;
        public static int VALUE_SERVICE_NOTIFY_ID_BASE = VALUE_SERVICE_NOTIFY_ID_START + 1;

        public static String REC_CACHE_PATH = AppPathUtils.createAppCacheFile("file").getAbsolutePath();

    }

    public static class Event {

    }

    public static class Path {

    }

    public static String getApMByIndex(int index) {
        switch (index) {
            case Value.VALUE_AM:
                return SlcResourceUtils.getString("app_label_am");
            case Value.VALUE_PM:
                return SlcResourceUtils.getString("app_label_pm");
            default:
                throw new IllegalStateException("上午下午状态码异常");
        }
    }
}
